package com.wcs.exam.common.enums;

import com.wcs.exam.common.base.BaseEnum;
import com.wcs.exam.common.constant.BaseConstant;
import lombok.AllArgsConstructor;
import lombok.Getter;

/**
 * 大模型类型
 *
 * @author wcs
 */
@Getter
@AllArgsConstructor
public enum LlmPlatformEnum implements BaseEnum {

    DEEPSEEK(80, "DeepSeek", BaseConstant.ModelType.DEEPSEEK + "%", BaseConstant.ModelType.DEEPSEEK),
    // TONGYI(60, "阿里通义", BaseConstant.ModelType.TONGYI + "%", BaseConstant.ModelType.TONGYI),
    // HUNYUAN(50, "腾讯混元", BaseConstant.ModelType.HUNYUAN + "%", BaseConstant.ModelType.HUNYUAN),
    // PANGU(40, "华为盘古", BaseConstant.ModelType.PANGU + "%", BaseConstant.ModelType.PANGU),
    ZHIPU(20, "智谱", BaseConstant.ModelType.ZHIPU + "%", BaseConstant.ModelType.ZHIPU);

    /**
     * 编码
     */
    private final Integer code;

    /**
     * 描述
     */
    private final String desc;

    /**
     * 标记
     */
    private final String tag;

    /**
     * 标记
     */
    private final String mode;

    /**
     * @param code 编码
     * @return 枚举
     */
    public static LlmPlatformEnum byCode(Integer code) {
        if (code == null) {
            return null;
        }
        for (LlmPlatformEnum value : LlmPlatformEnum.values()) {
            if (value.getCode().equals(code)) {
                return value;
            }
        }
        return null;
    }

}
